body {
    font-family: 'Microsoft YaHei', sans-serif;
    /* 修改背景样式以覆盖整个页面 */
    background: white url("images/background.png") no-repeat center center fixed;
    -webkit-background-size: cover;
    -moz-background-size: cover;
    -o-background-size: cover;
    background-size: cover;
    margin: 0;
    padding: 20px;
}
li a {
    color: green;
}
/* style.css */
/* style.css */
:root {
    --primary-color: #f97316;  /* 主色调-橙色 */
    --secondary-color: #42A5F5; /* 辅色调-蓝色 */
    --background-color: #f5f5f5;
}

body {
    font-family: 'Microsoft YaHei', sans-serif;
    background-color: var(--background-color);
    margin: 0;
    padding: 20px;
}

.container {
    max-width: 800px;
    margin: 0 auto;
    padding: 20px;
    animation: fadeIn 0.5s ease-out;
}

.page-title {
    font-size: 2.2em;
    margin-bottom: 10px;
    font-weight: 600;
    margin: 0 auto;
    color: var(--primary-color);
    text-shadow: 0 2px 4px rgba(255, 167, 38, 0.2);
    text-align: center;
    animation: bounce 1s infinite;
}

.page-subtitle {
    font-size: 1.2em;
    margin-bottom: 30px;
    color: #5D4037;
    text-align: center;
}

/* 定义跳动动画 */
@keyframes bounce {
    0%, 20%, 50%, 80%, 100% {
        transform: translateY(0);
    }
    40% {
        transform: translateY(-10px);
    }
    60% {
        transform: translateY(-5px);
    }
}

.poll-card {
    background: white;
    border-radius: 12px;
    box-shadow: 0 4px 20px rgba(0,0,0,0.08); /* 优化阴影 */
    margin-bottom: 25px;
    padding: 25px;
    transition: transform 0.3s ease, box-shadow 0.3s ease; /* 添加过渡效果 */
}

.poll-card:hover {
    transform: translateY(-3px); /* 悬停时轻微上浮 */
    box-shadow: 0 6px 25px rgba(0,0,0,0.12); /* 悬停时增强阴影 */
}

/* 其他样式保持不变 */

.poll-header {
    border-bottom: 2px solid #eee;
    padding-bottom: 15px;
    margin-bottom: 20px;
}

.poll-header h1, .poll-header h2 {
    font-size: 1.5em;
    font-weight: 600;
    color: #222;
}

.options-list {
    margin: 20px 0;
}

/* 改进选项样式 */
.option-item {
    padding: 15px 0;
    border-bottom: 1px solid #eee;
    transition: background 0.2s ease;
}

.option-item:hover {
    background: rgba(66, 165, 245, 0.05);
}

.option-item label {
    display: flex;
    align-items: center;
    cursor: pointer;
    font-size: 16px;
}

input[type="radio"] {
    display: none;
}

/* 改进单选按钮样式 */
.radio-circle {
    display: inline-block;
    width: 22px;
    height: 22px;
    border: 2px solid #ccc;
    border-radius: 50%;
    margin-right: 15px;
    position: relative;
    transition: border-color 0.3s ease;
}

input[type="radio"] {
    display: none; /* 隐藏原生按钮 */
}


input[type="radio"]:checked + .radio-circle {
    border-color: var(--secondary-color);
}

input[type="radio"]:checked + .radio-circle::after {
    content: '';
    position: absolute;
    top: 3px;
    left: 3px;
    width: 12px;
    height: 12px;
    background: var(--secondary-color);
    border-radius: 50%;
    animation: scaleIn 0.2s ease-out;
}

@keyframes scaleIn {
    from { transform: scale(0); }
    to { transform: scale(1); }
}

.form-actions {
    display: flex;
    gap: 15px;
    margin-top: 30px;
}
/* 按钮基础样式 */
.submit-btn, .vote-btn, .back-btn, .result-btn {
    padding: 12px 30px;
    border-radius: 25px;
    cursor: pointer;
    font-size: 16px;
    font-weight: 500;
    text-align: center;
    text-decoration: none;
    display: inline-block;
    transition: all 0.3s ease;
    background: linear-gradient(135deg, var(--secondary-color), #1E88E5); /* 添加渐变 */
    color: white;
    border: none;
    box-shadow: 0 4px 12px rgba(66, 165, 245, 0.3); /* 优化阴影 */
}


.submit-btn:active, .vote-btn:active {
    background: var(--primary-color); /* 点击时按钮变为橙色 */
}
.submit-btn:hover, .vote-btn:hover {
    background: #1E88E5;
    transform: translateY(-2px);
    box-shadow: 0 4px 12px rgba(66, 165, 245, 0.4);
}
/* 次按钮样式 */
.back-btn, .result-btn {
    background: white;
    color: var(--secondary-color);
    border: 2px solid var(--secondary-color);
    border-radius: 25px; /* 圆角按钮 */
    transition: all 0.3s ease;
}

.back-btn:hover, .result-btn:hover {
    background: rgba(66, 165, 245, 0.1);
    transform: translateY(-2px);
}

.back-btn:active, .result-btn:active {
    background: var(--primary-color); /* 点击查看结果和返回列表时变为橙色 */
    color: white;
}

.error-msg {
    color: #e53935;
    padding: 15px;
    background: #ffebee;
    border-radius: 8px;
    margin: 20px 0;
}

.poll-actions {
    display: flex;
    gap: 15px;
    margin-top: 20px;
}
/* 添加全局过渡效果 */
* {
    transition: all 0.3s ease;
}

/* 改进容器布局 */
.container {
    max-width: 800px;
    margin: 0 auto;
    padding: 20px;
    animation: fadeIn 0.5s ease-out;
}

/* 添加淡入动画 */
@keyframes fadeIn {
    from { opacity: 0; transform: translateY(10px); }
    to { opacity: 1; transform: translateY(0); }
}

/* 改进卡片阴影效果 */
.poll-card {
    background: white;
    border-radius: 12px;
    box-shadow: 0 4px 20px rgba(0,0,0,0.08);
    margin-bottom: 25px;
    padding: 25px;
    transition: transform 0.3s ease, box-shadow 0.3s ease;
}

.poll-card:hover {
    transform: translateY(-3px);
    box-shadow: 0 6px 25px rgba(0,0,0,0.12);
}

/* 响应式设计 */
@media (max-width: 768px) {
    .container {
        padding: 15px;
    }
    
    .poll-card {
        padding: 18px;
    }
    
    .form-actions, .poll-actions {
        flex-direction: column;/* 垂直排列按钮 */
        gap: 10px;
    }
    
    .submit-btn, .vote-btn, .back-btn, .result-btn {
        width: 100%;/* 按钮占满宽度 */
    }
    
    .vote-info {
        flex-direction: column;
        align-items: flex-start;
    }
    
    .progress-container {
        width: 100%;
        height: 14px;
        background-color: #f0f0f0;
        border-radius: 7px;
        overflow: hidden;
        margin-top: 8px;
    }
    .progress-bar {
        height: 100%;
        background: linear-gradient(90deg, var(--secondary-color), #64B5F6); /* 渐变填充 */
        transition: width 0.6s cubic-bezier(0.22, 0.61, 0.36, 1); /* 平滑动画 */
    }
}
/* 加载动画 */
@keyframes pulse {
    0%, 100% { opacity: 0.6; }
    50% { opacity: 1; }
}

.loading {
    animation: pulse 1.5s infinite;
}

/* 空状态样式 */
.no-polls {
    text-align: center;
    padding: 40px;
    color: #888;
    font-size: 18px;
    background: #f9f9f9;
    border-radius: 8px;
}

/* 错误消息改进 */
.error-msg {
    color: #e53935;
    padding: 15px;
    background: #ffebee;
    border-radius: 8px;
    margin: 20px 0;
    display: flex;
    align-items: center;
    gap: 10px;
}

.error-msg::before {
    content: "!";
    display: inline-block;
    width: 20px;
    height: 20px;
    background: #e53935;
    color: white;
    border-radius: 50%;
    text-align: center;
    line-height: 20px;
    font-weight: bold;
}

/* 点击效果 */
button, a {
    user-select: none;
}

button:active, a:active {
    transform: scale(0.98);
}

/* 禁用状态 */
button:disabled {
    opacity: 0.6;
    cursor: not-allowed;
    transform: none !important;
}
/* 添加在 :root 变量定义之后 */

/* 后台管理按钮区域 */
.admin-header {
    display: flex;
    justify-content: flex-end;
    margin-bottom: 20px;
}

/* 后台管理按钮样式 */
.admin-btn {
    padding: 10px 20px;
    background-color: #5D4037; /* 使用棕色系，与后台管理概念相关 */
    color: white;
    border-radius: 25px;
    text-decoration: none;
    font-weight: 500;
    transition: all 0.3s ease;
    box-shadow: 0 2px 5px rgba(0,0,0,0.1);
    display: inline-flex;
    align-items: center;
    gap: 8px;
}

.admin-btn:hover {
    background-color: #f97316;
    transform: translateY(-2px);
    box-shadow: 0 4px 8px rgba(0,0,0,0.15);
}

.admin-btn:active {
    transform: translateY(0);
    box-shadow: 0 2px 3px rgba(0,0,0,0.1);
}

/* 添加图标（使用伪元素） */
.admin-btn::before {
    content: "⚙️";
    font-size: 16px;
}

/* 响应式调整 */
@media (max-width: 768px) {
    .admin-header {
        margin-bottom: 15px;
    }
    
    .admin-btn {
        padding: 8px 16px;
        font-size: 14px;
    }
    .container {
        padding: 15px;
    }
}
.vote-instruction {
    color: #888;
    margin-bottom: 20px;
}
.result-title {
    font-size: 1.8em;
    color: var(--primary-color);
    text-shadow: 0 2px 4px rgba(255, 167, 38, 0.2);
}